#!/usr/bin/env python3

import pygame


pygame.init()

screen = pygame.display.set_mode((640, 480))
pygame.display.set_caption("My Game")

textfont = pygame.font.Font(None, 60)
textcolor = (255, 255, 255)

background_color = (0, 0, 0)
# render 4 text imgaes, with text 1, 2, 3, 4
text1 = textfont.render("1", True, textcolor)
text2 = textfont.render("2", True, textcolor)
text3 = textfont.render("3", True, textcolor)
text4 = textfont.render("4", True, textcolor)

center = screen.get_rect().center

while True:
    for event in pygame.event.get():
        if event.type in (pygame.QUIT, pygame.KEYDOWN):
            exit()
        screen.fill(background_color)
        # draw 4 text images
        screen.blit(text1, (center[0], center[1]-20))
        screen.blit(text2, (center[0]-20, center[1]-20))
        screen.blit(text3, (center[0]-20, center[1]+20))
        